package net.csdra.wenhua.nanan.qiandao;

import info.didyapp.weixin.WechatAdapter;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;

@SpringBootApplication
public class WenhuaNananQiandaoApplication {

	public static void main(String[] args) {
		SpringApplication.run(WenhuaNananQiandaoApplication.class, args);
	}

	@Bean
	WechatAdapter wechatAdapter(@Value("${weixin.appId}") String appId, @Value("${weixin.appSecret}") String appSecret) {
		return new WechatAdapter(appId, appSecret);
	}
}
